# Maintainer: Balló György <ballogyor+arch at gmail dot com>
# Contributor: Jan de Groot <jgc@archlinux.org>
# Contributor: Jaroslav Lichtblau <dragonlord@aur.archlinux.org>
# Contributor: Panagiotis Papadopoulos

pkgname=wildmidi
pkgver=0.4.5
pkgrel=2
pkgdesc='Simple software MIDI player which has a core softsynth library'
arch=('loong64' 'x86_64')
url='https://github.com/Mindwerks/wildmidi'
license=('GPL3' 'LGPL3')
depends=('alsa-lib' 'glibc')
makedepends=('cmake' 'ninja')
source=("https://github.com/Mindwerks/wildmidi/archive/$pkgname-$pkgver.tar.gz")
sha256sums=('116c0f31d349eaa74a630ed5a9a17b6a351204877a4ed9fb9aacd9dbd7f6c874')

build() {
  cmake -S $pkgname-$pkgname-$pkgver -B build -G Ninja -DCMAKE_INSTALL_PREFIX='/usr'
  cmake --build build
}

package() {
  DESTDIR="$pkgdir" cmake --install build
  ln -s wildmidi.pc "$pkgdir/usr/lib/pkgconfig/WildMIDI.pc"
}
